package com.nhim.core;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.ApplicationContext;
import org.springframework.stereotype.Repository;

@Repository
public class AppSettings {
	
	private String assets;
	
	@Value("${com.nhim.cms.admin.assetpath}")
	public void setAssetsPath(String assets) {
		this.assets = assets;
	}
	
	public String getAssetsPath()
	{
		return this.assets;
	}
	
	
	public static AppSettings getFromApplicationContext(
			ApplicationContext ctx) {
		return (AppSettings) ctx
				.getBean(AppSettings.class);
	}

}
